<template>
  <div class="purse">
      <view  class="init_purse">
          <view class="img_purse">
            <uv-image width="142rpx" height="132rpx" src="/static/jifen.png"></uv-image>
          </view>

          <view class="text_purse"> 我的积分</view>

          <view class="num_purse">¥ {{ myMarks }}</view>

          <view class="btn_purse" @click="jumpToPurse">积分明细</view>

        <view class="bit_s">  <view @click="gotoForm" class="line_purse_lim">立即提现</view></view>
      </view>




       
  </div>
</template>

<script setup>
import { onShow } from "@dcloudio/uni-app";
import { ref } from "vue";
import {getPurse} from '../https/api/purse'


let gotoForm = () => {
  uni.navigateTo({
    url: "/pages/purseForm"
  });
};

let detailList = ref([])
let myMarks = ref('')
onShow(async()=>{
  myMarks.value = uni.getStorageSync('rebateAmount')
  let res = await getPurse({})
  
  detailList.value = res.data.detailList
  uni.setStorageSync('detailList',JSON.stringify(res.data.detailList))
})

let jumpToPurse = ()=>{
 uni.navigateTo({
    url: "/pages/purseDetail"
  });
}

</script>

<style lang="scss" scoped>
.bit_s{
  margin-top: 20rpx;
  display: flex;

align-items: center;
justify-content: center;
}

.line_purse_lim{
  display: flex;

  align-items: center;
  justify-content: center;
  color: #009CFF;
  width: 441rpx;
height: 105rpx;
background: #FFFFFF;
border-radius: 5rpx;
border: 1rpx solid #E4E4E4;
}
.btn_purse{
  margin-top: 100rpx;
  font-family: Microsoft YaHei;
font-weight: 400;
font-size: 32rpx;
text-align: center;
color: #0063F8;
}
.num_purse{
  font-family: Microsoft YaHei;
font-weight: 400;
font-size: 64rpx;
color: #000000;
text-align: center;
margin-top: 20rpx;
}
.text_purse{
  margin-top: 20rpx;
  text-align: center;
  font-family: Microsoft YaHei;
font-weight: 400;
font-size: 32rpx;
color: #000000;

}
.img_purse{

  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 100rpx ;
}
.purse{
  border: 1rpx solid transparent;
 min-height: 100vh;
 background: #F8F8F8;
}
</style>